Skip to content

ci: add Linux ARM64 release build#2

Merged
Loongphy merged 10 commits intoLoongphy:mainfrom
flymin:main
May 8, 2026
Merged

ci: add Linux ARM64 release build#2
Loongphy merged 10 commits intoLoongphy:mainfrom
flymin:main

Conversation

@flymin
Copy link
Copy Markdown

@flymin flymin commented May 4, 2026

No description provided.

bolinfest and others added 5 commits April 30, 2026 08:06
- Added persisted `/goal` workflows with app-server APIs, model tools, runtime continuation, and TUI controls for create, pause, resume, and clear. (openai#18073, openai#18074, openai#18075, openai#18076, openai#18077, openai#20082)
- Added `codex update`, configurable TUI keymaps, plan-mode nudges, action-required terminal titles, and active-turn `/statusline` and `/title` edits. (openai#19933, openai#18593, openai#19901, openai#18372, openai#19917)
- Expanded permission profiles with built-in defaults, sandbox CLI profile selection, cwd controls, and active-profile metadata for clients. (openai#19900, openai#20117, openai#20118, openai#20095)
- Improved plugin workflows with marketplace installation, remote bundle caching, remote uninstall, plugin-bundled hooks, hook enablement state, and external-agent config import. (openai#18704, openai#19914, openai#19456, openai#19705, openai#19840, openai#19949)
- Added external agent session import, including background imports and imported-session title handling. (openai#19895, openai#20284, openai#20261)
- Made MultiAgentV2 configuration more explicit with thread caps, wait-time controls, root/subagent hints, and v2-specific depth handling. (openai#19360, openai#19792, openai#19805, openai#20052, openai#20180)

## Bug Fixes
- Fixed several resume and interruption issues, including stale interrupt hangs, persisted provider restoration, large remote resume responses, and slow filtered resume lists. (openai#18392, openai#19287, openai#19920, openai#19591)
- Improved TUI reliability around terminal resize reflow, markdown list spacing, slash-command popup layout, keyboard cleanup, shell-mode escape, and working status updates. (openai#18575, openai#19706, openai#19511, openai#19625, openai#19986, openai#19939)
- Hardened managed network behavior for deferred denials, proxy bypass defaults, resolved target checks, IPv6 host matching, and `git -C` approval handling. (openai#19184, openai#20002, openai#19999, openai#19995, openai#20085)
- Fixed Windows sandbox and PTY edge cases, including pseudoconsole startup, elevated runner process handling, core shell environment inheritance, and named-pipe validation. (openai#20042, openai#19211, openai#20089, openai#19283)
- Fixed Bedrock model support for `apply_patch`, GPT-5.4 reasoning levels, and updated Bedrock GPT-5.4 endpoint/model metadata. (openai#19416, openai#19461, openai#20109)
- Fixed MCP/plugin edge cases around stdio server cleanup, plugin MCP approval persistence, and custom MCP metadata isolation. (openai#19753, openai#19537, openai#19836, openai#19875)

## Documentation
- Updated the bundled OpenAI Docs skill for GPT-5.5, `gpt-image-2`, and clearer upgrade guidance. (openai#19407, openai#19443, openai#19422)
- Clarified contributor-facing docs, including the PR template, Rust async trait guidance, and README wording. (openai#19912, openai#20242, openai#19514)
- Added a checked-in `codex-core` public API listing and a ThreadManager sample crate. (openai#20243, openai#20141)

## Chores
- Published `codex-app-server` release artifacts, stopped publishing GNU Linux binaries, and increased release workflow timeouts. (openai#19447, openai#19445, openai#20271, openai#20343)
- Added Codex-pinned versioning for the Python app-server SDK package. (openai#18996)
- Deprecated `--full-auto` while steering users toward explicit permission profiles and trust flows. (openai#20133)
- Stabilized CI and release plumbing with Bazel setup migration, release smoke-test pinning, and updated workflow pins/timeouts. (openai#19851, openai#19854, openai#19472, openai#19609)

## Changelog

Full Changelog: openai/codex@rust-v0.125.0...rust-v0.128.0

- openai#19124 Make MultiAgentV2 interruption markers assistant-authored @jif-oai
- openai#19354 chore: alias max_concurrent_threads_per_session @jif-oai
- openai#19360 feat: surface multi-agent thread limit in spawn description @jif-oai
- openai#19351 Add agents.interrupt_message for interruption markers @jif-oai
- openai#18392 Fix hang on turn/interrupt @danwang-oai
- openai#19380 chore: drop MCP Plugins and App from Morpheus @jif-oai
- openai#18907 respect workspace option for disabling plugins @zamoshchin-openai
- openai#19283 check PID of named pipe consumer @iceweasel-oai
- openai#19407 Update bundled OpenAI Docs skill for GPT-5.5 @kkahadze-oai
- openai#19163 Harden package-manager install policy @mcgrew-oai
- openai#19416 Fix: use function apply_patch tool for Bedrock model @celia-oai
- openai#19093 [codex] Omit fork turns from thread started notifications @euroelessar
- openai#19244 Update unix socket transport to use WebSocket upgrade @willwang-openai
- openai#19170 Skip disabled rows in selection menu numbering and default focus @canvrno-oai
- openai#19414 permissions: make legacy profile conversion cwd-free @bolinfest
- openai#18900 Migrate fork and resume reads to thread store @wiltzius-openai
- openai#19445 ci: stop publishing GNU Linux release artifacts @bolinfest
- openai#19443 Add gpt-image-2 to bundled OpenAI Docs skill @kkahadze-oai
- openai#18584 [4/4] Honor Streamable HTTP MCP placement @aibrahim-oai
- openai#19447 ci: publish codex-app-server release artifacts @bolinfest
- openai#19422 Clarify bundled OpenAI Docs upgrade guide wording @kkahadze-oai
- openai#19266 [codex] add non-local thread store regression harness @wiltzius-openai
- openai#19098 feat: Compress skill paths with root aliases @xl-openai
- openai#19207 [codex] Forward Codex Apps tool call IDs to backend metadata @rreichel3-oai
- openai#19453 Serialize legacy Windows PowerShell sandbox tests @dylan-hurd-oai
- openai#19234 Refactor log DB into LogWriter interface @rasmusrygaard
- openai#19461 fix: Bedrock GPT-5.4 reasoning levels @celia-oai
- openai#19449 permissions: remove legacy read-only access modes @bolinfest
- openai#19472 ci: pin codex-action v1.7 @viyatb-oai
- openai#19468 Fix Bazel cargo_bin runfiles paths @fjord-oai
- openai#19410 Remove js_repl feature @fjord-oai
- openai#18073 Add goal persistence foundation (1 / 5) @etraut-openai
- openai#18074 Add goal app-server API (2 / 5) @etraut-openai
- openai#18075 Add goal model tools (3 / 5) @etraut-openai
- openai#18076 Add goal core runtime (4 / 5) @etraut-openai
- openai#18077 Add goal TUI UX (5 / 5) @etraut-openai
- openai#19454 Split approval matrix test groups @dylan-hurd-oai
- openai#19514 Fix codex-rs README grammar @etraut-openai
- openai#19459 Enable unavailable dummy tools by default @mzeng-openai
- openai#19524 [codex] Prune unused codex-mcp API and duplicate helpers @aibrahim-oai
- openai#19526 [codex] Order codex-mcp items by visibility @aibrahim-oai
- openai#19578 fix: increase Bazel timeout to 45 minutes @bolinfest
- openai#19287 Restore persisted model provider on thread resume @etraut-openai
- openai#19593 test: isolate remote thread store regression from plugin warmups @bolinfest
- openai#19511 Keep slash command popup columns stable while scrolling @etraut-openai
- openai#19595 [codex] Bypass managed network for escalated exec @viyatb-oai
- openai#19604 test: stabilize app-server path assertions on Windows @bolinfest
- openai#19609 fix: restore 30-minute timeout for Bazel builds @bolinfest
- openai#19389 Guard npm update readiness @shijie-oai
- openai#18575 fix(tui): reflow scrollback on terminal resize @fcoury-oai
- openai#19610 Support end_turn in response.completed @andmis
- openai#19640 [codex] remove responses command @tibo-openai
- openai#19683 test: harden app-server integration tests @bolinfest
- openai#18904 feat: load AgentIdentity from JWT login/env @efrazer-oai
- openai#19606 permissions: make runtime config profile-backed @bolinfest
- openai#19392 permissions: derive compatibility policies from profiles @bolinfest
- openai#19484 Lift app-server JSON-RPC error handling to request boundary @pakrym-oai
- openai#19487 [codex] Move config loading into codex-config @pakrym-oai
- openai#19393 permissions: migrate approval and sandbox consumers to profiles @bolinfest
- openai#19726 Fix codex-core config test type paths @pakrym-oai
- openai#19727 test: increase core-all-test shard count to 16 @bolinfest
- openai#19725 Split MCP connection modules @aibrahim-oai
- openai#19605 Delete unused ResponseItem::Message.end_turn @andmis
- openai#19394 permissions: remove core legacy policy round trips @bolinfest
- openai#19733 Allow agents.max_threads to work with multi_agent_v2 @andmis
- openai#19395 permissions: finish profile-backed app surfaces @bolinfest
- openai#19739 inline hostname resolution for remote sandbox config @abhinav-oai
- openai#19734 permissions: centralize legacy sandbox projection @bolinfest
- openai#19058 Add /auto-review-denials retry approval flow @won-openai
- openai#19735 permissions: store only constrained permission profiles @bolinfest
- openai#19736 permissions: constrain requirements as profiles @bolinfest
- openai#19737 permissions: derive legacy exec policies at boundaries @bolinfest
- openai#19779 Add Codex issue digest skill @etraut-openai
- openai#19792 multi_agent_v2: move thread cap into feature config @jif-oai
- openai#18982 feat: use git-backed workspace diffs for memory consolidation @jif-oai
- openai#19809 Allow Phase 2 memory claims after retry exhaustion @jif-oai
- openai#19812 Avoid rewriting Phase 2 selection on clean workspace @jif-oai
- openai#19813 nit: one more fix @jif-oai
- openai#19818 chore: split memories part 1 @jif-oai
- openai#19510 Hide rewind preview when no user message exists @etraut-openai
- openai#19618 Persist shell mode commands in prompt history @etraut-openai
- openai#19709 Render delegated patch approval details @etraut-openai
- openai#19490 Streamline plugin, apps, and skills handlers @pakrym-oai
- openai#19762 refactor: make auth loading async @efrazer-oai
- openai#19854 ci: pin npm staging smoke test to a recent rust-release run @bolinfest
- openai#19851 ci: migrate Bazel setup away from archived setup-bazelisk @bolinfest
- openai#19491 Streamline account and command handlers @pakrym-oai
- openai#19771 fix: filter dynamic deferred tools from model_visible_specs @sayan-oai
- openai#19863 [codex-analytics] remove ga flag @rhan-oai
- openai#19865 Cap original-detail image token estimates @fjord-oai
- openai#19591 Fix filtered thread-list resume regression in TUI @etraut-openai
- openai#19513 Delay approval prompts while typing @etraut-openai
- openai#19706 Preserve TUI markdown list spacing after code blocks @etraut-openai
- openai#19841 permissions: remove cwd special path @bolinfest
- openai#19492 Streamline thread start handler @pakrym-oai
- openai#19874 [codex-backend] Prefer state git metadata in filtered thread lists @joeytrasatti-openai
- openai#19493 Streamline thread mutation handlers @pakrym-oai
- openai#19862 [codex] Shard exec Bazel integration test @starr-openai
- openai#18996 Publish Python SDK with Codex-pinned versioning @sdcoffey
- openai#19494 Streamline thread read handlers @pakrym-oai
- openai#19839 [codex] Trace cancelled inference streams @cassirer-openai
- openai#19495 Streamline thread resume and fork handlers @pakrym-oai
- openai#19497 Streamline turn and realtime handlers @pakrym-oai
- openai#18372 Show action required in terminal title @canvrno-oai
- openai#19884 Add MCP app feature flag @mzeng-openai
- openai#19498 Streamline review and feedback handlers @pakrym-oai
- openai#19772 permissions: derive config defaults as profiles @bolinfest
- openai#19836 disallow fileparams metadata for custom mcps @colby-oai
- openai#19892 Refactor exec-server filesystem API into codex-file-system @miz-openai
- openai#19452 Stabilize plugin MCP fixture tests @dylan-hurd-oai
- openai#19481 Remove ghost snapshots  @pakrym-oai
- openai#19773 permissions: require profiles in TUI thread state @bolinfest
- openai#19917 Allow /statusline and /title slash commands during active turns @canvrno-oai
- openai#19763 refactor: load agent identity runtime eagerly @efrazer-oai
- openai#17689 [codex-analytics] include user agent in default headers @marksteinbrick-oai
- openai#19912 Clarify PR template invitation requirement @etraut-openai
- openai#19630 Avoid persisting ShutdownComplete after thread shutdown @etraut-openai
- openai#19774 permissions: make SessionConfigured profile-only @bolinfest
- openai#19775 permissions: derive snapshot sandbox projections @bolinfest
- openai#19920 Allow large remote app-server resume responses @etraut-openai
- openai#19776 permissions: store thread sessions as profiles @bolinfest
- openai#19899 app-server-protocol: mark permission profiles experimental @bolinfest
- openai#19933 Add `codex update` command @etraut-openai
- openai#19914 feat: Cache remote plugin bundles on install @xl-openai
- openai#19456 Add remote plugin uninstall API @xli-oai
- openai#19805 Add MultiAgentV2 root and subagent context hints @jif-oai
- openai#19860 feat: split memories part 2 @jif-oai
- openai#19961 feat: fix hinting 2 @jif-oai
- openai#19963 feat: fix hinting 3 @jif-oai
- openai#19967 Stabilize memory Phase 2 input ordering @jif-oai
- openai#19970 feat: trigger memories from user turns with cooldown @jif-oai
- openai#19904 fix: configure AgentIdentity AuthAPI base URL @efrazer-oai
- openai#19990 feat: skip memory startup when Codex rate limits are low @jif-oai
- openai#19998 feat: house-keeping memories 1 @jif-oai
- openai#20000 feat: house-keeping memories 2 @jif-oai
- openai#19832 Preserve assistant phase for replayed messages @friel-openai
- openai#19625 Reset TUI keyboard reporting on exit @etraut-openai
- openai#18593 feat(tui): add configurable keymap support @fcoury-oai
- openai#19846 [sandbox] Enforce protected workspace metadata paths @evawong-oai
- openai#20005 feat: house-keeping memories 3 @jif-oai
- openai#19929 TUI: use cumulative turn duration for worked-for separator @etraut-openai
- openai#19753 Terminate stdio MCP servers on shutdown to avoid process leaks @etraut-openai
- openai#19473 Add turn start timestamp to turn metadata @mchen-oai
- openai#19875 Strip connector provenance metadata from custom MCP tools @colby-oai
- openai#19764 feat: verify agent identity JWTs with JWKS @efrazer-oai
- openai#19847 Enforce workspace metadata protections in Seatbelt @evawong-oai
- openai#19509 Record MCP result telemetry on mcp.tools.call spans @mchen-oai
- openai#19907 Clarify network approval auto-review prompts @maja-openai
- openai#19901 feat(tui): suggest plan mode from composer drafts @fcoury-oai
- openai#19931 Move local /resume cwd filtering into thread/list @canvrno-oai
- openai#19986 fix(tui): let esc exit empty shell mode @fcoury-oai
- openai#19895 External agent session support @stefanstokic-oai
- openai#20002 fix(network-proxy): tighten network proxy bypass defaults @viyatb-oai
- openai#19900 permissions: add built-in default profiles @bolinfest
- openai#20045 Fix plan mode nudge test after task completion signature change @canvrno-oai
- openai#19432 [codex] Add token usage to turn tracing spans @charley-openai
- openai#20001 fix(network-proxy): harden linux proxy bridge helpers @viyatb-oai
- openai#19959 Fix log db batch flush flake @dylan-hurd-oai
- openai#17373 app-server: run initialized rpcs with keyed serialization @euroelessar
- openai#19708 Load cloud requirements for agent identity @shijie-oai
- openai#19999 fix(network-proxy): recheck network proxy connect targets @viyatb-oai
- openai#20047 app-server: allow remote_control runtime feature override @euroelessar
- openai#20052 Make MultiAgentV2 wait minimum configurable @jif-oai
- openai#20008 tui: use permission profiles for sandbox state @bolinfest
- openai#20068 app-server: disable remote control without sqlite @euroelessar
- openai#20066 [rollout-trace] Include x-request-id in rollout trace. @cassirer-openai
- openai#19705 Discover hooks bundled with plugins @abhinav-oai
- openai#18704 /plugins: add marketplace install flow @canvrno-oai
- openai#20085 fix: don't auto approve git -C ... @owenlin0
- openai#20088 Fix flaky plugin hook env test @abhinav-oai
- openai#19995 fix(network-proxy): normalize network proxy host matching @viyatb-oai
- openai#20010 core tests: submit turns with permission profiles @bolinfest
- openai#20092 Return None when auth refresh fails @gpeal
- openai#19919 app-server: notify clients of remote-control status changes @euroelessar
- openai#20097 Refine Codex issue digest summaries @etraut-openai
- openai#20011 core tests: build user turns from permission profiles @bolinfest
- openai#20013 core tests: migrate more turns to permission profiles @bolinfest
- openai#20015 core tests: configure profiles directly @bolinfest
- openai#20016 core tests: send model turns with permission profiles @bolinfest
- openai#20100 Increase plugin hook env test timeout @abhinav-oai
- openai#20018 core tests: migrate model/personality turns to profiles @bolinfest
- openai#20021 core tests: migrate view image turns to profiles @bolinfest
- openai#20024 core tests: migrate safety check turns to profiles @bolinfest
- openai#20026 core tests: migrate plan item turns to profiles @bolinfest
- openai#20027 core tests: migrate tools tests to permission profiles @bolinfest
- openai#20028 core tests: migrate permissions message tests to profiles @bolinfest
- openai#20030 core tests: migrate exec policy turns to profiles @bolinfest
- openai#20032 core tests: migrate prompt caching turns to profiles @bolinfest
- openai#20033 core tests: migrate request permissions tool turns to profiles @bolinfest
- openai#20034 core tests: migrate zsh-fork permissions to profiles @bolinfest
- openai#20035 core tests: migrate compact turns to profiles @bolinfest
- openai#20037 core tests: migrate rmcp turns to profiles @bolinfest
- openai#20040 core tests: migrate apply patch turns to profiles @bolinfest
- openai#20041 core tests: migrate hook turns to profiles @bolinfest
- openai#20072 Support disabling tool suggest for specific tools. @mzeng-openai
- openai#19949 Support detect and import MCP, Subagents, hooks, commands from external @alexsong-oai
- openai#19442 feat: disable capabilities by model provider @celia-oai
- openai#20108 fix: restore live event submit path for apply patch tests @bolinfest
- openai#19939 Restore TUI working status after steer message is set @canvrno-oai
- openai#20086 Fix plugin list workspace settings test isolation @canvrno-oai
- openai#20049 feat: expose provider capability bounds to app server clients @celia-oai
- openai#20109 feat: update Bedrock Mantle endpoint and GPT-5.4 model ID @celia-oai
- openai#20106 linux-sandbox: switch helper plumbing to PermissionProfile @bolinfest
- openai#20112 Soften skill description budget warnings @xl-openai
- openai#20058 Add environment provider snapshot @starr-openai
- openai#20133 chore(cli) deprecate --full-auto @dylan-hurd-oai
- openai#20117 feat(cli): add explicit sandbox permission profiles @viyatb-oai
- openai#20139 Delete multi_agent_v2 followup_task interrupt parameter @andmis
- openai#20118 feat(cli): add sandbox profile config controls @viyatb-oai
- openai#20144 Fix migrated hook path rewriting @alexsong-oai
- openai#20042 Fix Windows pseudoconsole attribute handling for sandboxed PTY sessions @iceweasel-oai
- openai#20186 nit: drop old memories things @jif-oai
- openai#20180 Make multi-agent v2 ignore agents.max_depth @jif-oai
- openai#20082 Use /goal resume for paused goals @etraut-openai
- openai#20172 TUI: Remove core protocol dependency [1/7] @etraut-openai
- openai#19211 Improve Windows process management edge cases @iceweasel-oai
- openai#20123 [rollout-tracer] Match analysis messages on encrypted id. @cassirer-openai
- openai#20173 TUI: Remove core protocol dependency [2/7] @etraut-openai
- openai#20174 TUI: Remove core protocol dependency [3/7] @etraut-openai
- openai#20228 [codex-backend] Prefer sqlite git info for rollout-path reads @joeytrasatti-openai
- openai#20141 Add ThreadManager sample crate @pakrym-oai
- openai#20046 test protocol: lock inter-agent commentary phase @friel-openai
- openai#20064 Include auto-review rollout in feedback uploads @won-openai
- openai#20096 feat: Use remote installed plugin cache for skills and MCP @xl-openai
- openai#19184 fix: handle deferred network proxy denials @viyatb-oai
- openai#20089 expand the set of core shell env vars for Windows. @iceweasel-oai
- openai#17088 [codex-analytics] ingest server requests and responses @rhan-oai
- openai#20091 [tool_suggest] Improve tool_suggest triggering conditions. @mzeng-openai
- openai#20258 app-server: fix outgoing sender test setup @sayan-oai
- openai#20050 [app-server] type client response payloads @rhan-oai
- openai#19966 Require remote plugin detail before uninstall @xli-oai
- openai#20059 [app-server] centralize client response analytics @rhan-oai
- openai#19334 Fallback login callback port when default is busy @xli-oai
- openai#20231 [apps] Add apps MCP path override @adaley-openai
- openai#20242 docs: discourage `#[async_trait]` and `#[allow(async_fn_in_trait)]` @bolinfest
- openai#19620 Escape turn metadata headers as ASCII JSON @etraut-openai
- openai#19537 [mcp] Fix plugin MCP approval policy. @mzeng-openai
- openai#19229 Add agent graph store interface @rasmusrygaard
- openai#20243 Add codex-core public API listing @pakrym-oai
- openai#19435 stop blocking unified_exec on Windows @iceweasel-oai
- openai#19852 Enforce workspace metadata protections in Linux sandbox @evawong-oai
- openai#20136 Update Codex login success page UX @rafael-jac
- openai#20271 chore: increase release build timeout from 60 min to 90 @bolinfest
- openai#19778 Add hooks/list app-server RPC @abhinav-oai
- openai#20261 Consume ai-title from external sessions and add end marker @alexsong-oai
- openai#20284 Import external agent sessions in background @stefanstokic-oai
- openai#20149 Reduce the surface of collaboration modes @pakrym-oai
- openai#20282 tui: return from side chat on Ctrl-D @etraut-openai
- openai#20250 update codex_plugins_beta_setting (from workspace settings) @zamoshchin-openai
- openai#20080 [codex-analytics] prevent stale guardian events from satisfying reused reviews @rhan-oai
- openai#20291 app-server: remove dead api version handling from bespoke events @pakrym-oai
- openai#20304 [plugins] Allow MSFT curated plugins in tool_suggest @mzeng-openai
- openai#20095 permissions: expose active profile metadata @bolinfest
- openai#19840 Add persisted hook enablement state @abhinav-oai
- openai#20343 ci: increase Windows release workflow timeouts @bolinfest
Loongphy added 2 commits May 8, 2026 11:05
# Conflicts:
#	.github/workflows/rust-release.yml
#	README.md
#	codex-cli/bin/codex.js
#	codex-cli/scripts/build_npm_package.py
#	codex-rs/Cargo.lock
#	codex-rs/Cargo.toml
#	codex-rs/app-server-protocol/schema/typescript/v2/GetAccountParams.ts
#	codex-rs/app-server-protocol/src/protocol/v2.rs
#	codex-rs/app-server/src/codex_message_processor.rs
#	codex-rs/core/src/session/mod.rs
#	codex-rs/tui/src/app.rs
#	codex-rs/tui/src/app/event_dispatch.rs
#	codex-rs/tui/src/app_event.rs
#	codex-rs/tui/src/chatwidget.rs
Loongphy pushed a commit to flymin/codext that referenced this pull request May 8, 2026
…i#21190)

## Why

We found this while reviewing openai#21091, but confirmed it is not introduced
by that PR: the order-sensitive `current_text_with_pending()`
replacement loop already existed, and `main` already allowed active
same-size large pastes to use prefix-overlapping labels such as `[Pasted
Content N chars]` and `[Pasted Content N chars] Loongphy#2`.

openai#21091 fixes placeholder numbering after a draft is cleared, so a fresh
same-size paste can reuse the base label. This PR fixes a different
path: when a draft already contains multiple active same-size large
pastes, the placeholders can overlap by prefix, for example `[Pasted
Content N chars]` and `[Pasted Content N chars] Loongphy#2`.

That overlap breaks `current_text_with_pending()` when the composer
materializes the draft text for the external editor. Replacing the base
placeholder first can partially rewrite the `Loongphy#2` placeholder, leaving
the external editor seeded with corrupted text instead of both paste
payloads.

| Before | After |
|---|---|
| <img width="1230" height="1008" alt="CleanShot 2026-05-05 at 10 18 09"
src="https://github.com/user-attachments/assets/88a2936c-cf00-4adc-8567-8fd8f398b4a8"
/> | <img width="1230" height="1008" alt="CleanShot 2026-05-05 at 10 20
31"
src="https://github.com/user-attachments/assets/119cff52-43c8-432a-9367-418d82f4ed82"
/> |
| <img width="1230" height="1008" alt="CleanShot 2026-05-05 at 10 18 57"
src="https://github.com/user-attachments/assets/026031bb-839b-4252-a0fd-9ba9616435fe"
/> | <img width="1230" height="1008" alt="CleanShot 2026-05-05 at 10 21
31"
src="https://github.com/user-attachments/assets/8cb6f2c8-3a5d-411b-8623-dca666ee3c08"
/> |

## What Changed

- Changed `current_text_with_pending()` to expand pending pastes through
the existing element-range based `expand_pending_pastes()` helper
instead of global string replacement.
- Added a regression test with two different same-length large pastes to
ensure both overlapping placeholders expand to their original payloads.

## How to Test

1. Start Codex TUI.
2. Paste a large string, for example 1004 `A` characters.
```shell
perl -e 'print "A" x 1004' | pbcopy
```
3. Paste a second large string with the same length, for example 1004
`B` characters.
```shell
perl -e 'print "B" x 1004' | pbcopy
```
4. Open the external editor from the composer.
5. Confirm the editor is seeded with the full `A...` payload followed by
the full `B...` payload, with no literal `Loongphy#2` left behind.

Targeted tests:
- `cargo test -p codex-tui
current_text_with_pending_expands_overlapping_placeholders`
- `just argument-comment-lint-from-source -p codex-tui`

I also ran `cargo test -p codex-tui`; it reached the full crate suite
but failed two unrelated local status tests because this machine's
`/etc/codex/requirements.toml` rejects `DangerFullAccess`.
@Loongphy
Copy link
Copy Markdown
Owner

Loongphy commented May 8, 2026

Thanks for your contribution

@Loongphy Loongphy merged commit ae9dca2 into Loongphy:main May 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants